import Engines from '@/utils/engine.js'

const engine = new Engines()

const api = {
  types: '/adminApi/newsClassManagement/getNewsClassList',
  addtype: '/adminApi/newsClassManagement/addNewsClass',
  updateType: '/adminApi/newsClassManagement/updateNewsClass',
  deleteType: '/adminApi/newsClassManagement/deleteNewsClass',
  getNews: '/adminApi/newsManagement/getNewsList',
  addNews: '/adminApi/newsManagement/addNews',
  deleteNews: '/adminApi/newsManagement/deleteNews',
  getRecommendClassList: '/adminApi/recommendManagement/getNewsRecommendClassList',
  getNewsDetail: '/adminApi/newsManagement/getNewsDetail',
  updateNews: '/adminApi/newsManagement/updateNews',
  addTemplate: '/work_card_template/add_template',
  getTemplateList:'/work_card_template/get_template_list',
  getTemplateInfo:'/work_card_template/get_template_info',
  getStatusList:'/work_card_template/get_template_status_list',
  getCodeInfo:'/work_card_template/get_template_code_info',
  certList: '/work_permit_audit/work_cert_list',
  certInfo: '/work_permit_audit/work_cert_info',
  certcertUp: '/work_permit_audit/work_cert_up',
  getSeal: '/work_card_template/get_company_seal',
  getAloneCode: '/work_permit_audit/work_cert_separate',
  getCertStatusList: '/work_permit_audit/work_cert_status_list',
  getCompanyInfo: '/work_card_template/get_company_info',
}

export default api

// new 获取新增模版企业单位
export function getCompanyInfo(param) {
  return engine._request2({
    url: api.getCompanyInfo,
    method: 'POST',
    param: param
  })
}
// new 新增证件模版
export function addTemplate(param) {
  return engine._request2({
    url: api.addTemplate,
    method: 'POST',
    param: param
  })
}
// new 请求证件制作列表
export function getTemplateList(param){
  return engine._request2({
    url: api.getTemplateList,
    method: 'POST',
    param: param
  })
}
// new 请求证件模版详情
export function getTemplateInfo(param){
  return engine._request2({
    url: api.getTemplateInfo,
    method: 'POST',
    param: param
  })
}
// new 请求证件模版列表状态
export function getStatusList(param){
  return engine._request2({
    url: api.getStatusList,
    method: 'POST',
    param: param
  })
}
// new 获取邀请认证二维码
export function getCodeInfo(param){
  return engine._request2({
    url: api.getCodeInfo,
    method: 'POST',
    param: param
  })
}
// new 获取单独认证二维码
export function getAloneCode(param){
  return engine._request2({
    url: api.getAloneCode,
    method: 'POST',
    param: param
  })
}
// new 发证管理列表
export function certList(param) {
  return engine._request2({
    url: api.certList,
    method: 'POST',
    param: param
  })
}
// new 发证管理列表详情
export function certInfo(param) {
  return engine._request2({
    url: api.certInfo,
    method: 'POST',
    param: param
  })
}
// new 发证管理列表状态修改
export function certcertUp(param) {
  return engine._request2({
    url: api.certcertUp,
    method: 'POST',
    param: param
  })
}
// new 获取企业印章
export function getSeal(param) {
  return engine._request2({
    url: api.getSeal,
    method: 'POST',
    param: param
  })
}
// new 获取发证管理状态列表
export function getCertStatusList(param) {
  return engine._request2({
    url: api.getCertStatusList,
    method: 'POST',
    param: param
  })
}


